@<template>
  <div class="detail-goods-info">
    <div class="detail-image">
      <img
        v-for="(item, index) in detailImage"
        :key="index"
        :src="item"
        alt=""
        @load="imgLoad"
      />
    </div>
  </div>
</template>

<script>
export default {
  props: {
    detailImage: {
      type: Array,
      default: [],
    },
  },
  data(){
    return {
        count: 0,
    }
  },
  methods: {
    imgLoad() {
        if(++this.count == this.detailImage.length) {
            this.$emit('detailrefresh')
        }
    }
  }
};
</script>

<style>
.detail-goods-info {
  width: 100%;
}

.detail-image img {
  width: 100%;
}
</style>